Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 7dc3e6c66e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
contracts/tron/TronImports.sol
Outdated
| // and must be in a separate file from counterfactual contracts (OZ v4) to avoid name collisions. | ||
| import "../sp1-helios/SP1Helios.sol"; | ||
| import "../sp1-helios/SP1AutoVerifier.sol"; | ||
| import "../Universal_SpokePool.sol"; |
There was a problem hiding this comment.
Fix Universal_SpokePool import path in Tron entrypoint
TronImports.sol imports ../Universal_SpokePool.sol, but this repository only contains contracts/spoke-pools/Universal_SpokePool.sol. Because profile.tron compiles contracts/tron as its source root, this bad relative path makes the Tron build fail before any deployment script can run. Point the import at the actual file location so FOUNDRY_PROFILE=tron forge build can resolve the contract graph.
Useful? React with 👍 / 👎.
| import { deployContract, resolveChainId } from "../deploy"; | ||
|
|
||
| async function main(): Promise<void> { | ||
| const chainId = resolveChainId(); |
There was a problem hiding this comment.
Restrict SP1AutoVerifier deployments off mainnet by default
SP1AutoVerifier is a no-op verifier that accepts any proof, but this script resolves chain ID with mainnet as the default when --testnet is omitted. That creates a high-risk footgun where a routine run can deploy an insecure verifier to Tron mainnet and later be wired into SP1Helios, effectively disabling proof validation. Require an explicit opt-in for mainnet (or hard-block it) to prevent accidental insecure production deployments.
Useful? React with 👍 / 👎.
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
Signed-off-by: bennett <bennett@umaproject.org>
Co-authored-by: bmzig <57361391+bmzig@users.noreply.github.com>
fusmanii
left a comment
There was a problem hiding this comment.
Deployments look good, just couple comments about updating constants to fetch latest tron chain info
broadcast/deployed-addresses.json
Outdated
| } | ||
| }, | ||
| "728126428": { | ||
| "chain_name": "Chain 728126428", |
There was a problem hiding this comment.
This name comes from the https://github.com/across-protocol/constants, looks like Tron has been added there so we just need to bump constants version to latest here
There was a problem hiding this comment.
updated here: 278bd5d
had to make a minor change to GenerateConstantsJson.ts as the constants repo was recently updated to ts6
broadcast/deployed-addresses.md
Outdated
|
|
||
| | Contract Name | Address | | ||
| | -------------------------------- | ---------------------------------- | | ||
| | CounterfactualDeposit | TUE4j3wvnJf5Qwo9ZdYS9XebFzbMMvisEy | |
There was a problem hiding this comment.
same with this, once you bump the version, it should also pull the explorer link
|
|
||
| const proxyArtifactPath = path.resolve(__dirname, "../../../out-tron/ERC1967Proxy.sol/ERC1967Proxy.json"); | ||
|
|
||
| const proxyResult = await deployContract({ |
There was a problem hiding this comment.
it looks like this script is deploying the proxy every time. Is there a way to make it only deploy if it can't find an already deployed proxy?
|
|
||
| const evmChainId = (await ethersProvider.getNetwork()).chainId; | ||
| const usdcAddress = TOKEN_SYMBOLS_MAP.USDC.addresses[evmChainId]; | ||
| const usdcAddress = TOKEN_SYMBOLS_MAP.USDC.addresses[evmChainId as keyof typeof TOKEN_SYMBOLS_MAP.USDC.addresses]; |
There was a problem hiding this comment.
Changes needed due to constants repo updating to ts6
Adds scripts for deploying counterfactuals, UniversalSpokePool, SP1Helios, and SP1HeliosAutoVerifier contracts, and deploys these contracts to Tron. Includes changes from the audit branch.